home *** CD-ROM | disk | FTP | other *** search
/ Aminet 44 / Aminet 44 (2001)(GTI - Schatztruhe)[!][Aug 2001].iso / Aminet / game / patch / WHDIGamesJ-M.lzh / MagicPockets.lha / MagicPocketsHD / Install-MagicPockets next >
Text File  |  2001-04-03  |  2KB  |  118 lines

  1.  
  2. (set #drwname "MagicPockets")
  3.  
  4. ;try to figure out a place where the user usually installs his games
  5. (if (exists "Games:" (noreq) )
  6.     (set @default-dest "Games:")
  7.     (if (exists "SYS:Games" (noreq) )
  8.         (set @default-dest "SYS:Games")
  9.         (if (exists "Work:Games" (noreq) )
  10.             (set @default-dest "Work:Games")
  11.             (if (exists "JEUX:" (noreq) )
  12.                (set @default-dest "JEUX:")
  13.                (set @default-dest "SYS:")
  14.             )
  15.         )
  16.     )
  17. )
  18.  
  19.  
  20. (set default-dest
  21. (askdir
  22.     (prompt ("Where should %s installed ?\nA drawer \"%s\" will automatically created." @app-name #drwname))
  23.     (help @askdir-help)
  24.     (default @default-dest)
  25.     (disk)
  26. )
  27. )
  28.  
  29. (set @default-dest (tackon default-dest #drwname))
  30.  
  31.  
  32. (set #CI_unit
  33.     (askchoice
  34.         (prompt "From which disk unit do you want\nto install the game")
  35.         (help    @askoptions-help)
  36.         (choices
  37.            "DF0:"
  38.            "DF1:"
  39.            "DF2:"
  40.            "DF3:"
  41.         )
  42.     )
  43. )
  44.  
  45.  
  46. (set #gamever
  47.     (askchoice
  48.         (prompt "Which version do you want to install?")
  49.         (help    @askoptions-help)
  50.         (choices
  51.            "JST"
  52.            "WHDLoad"
  53.         )
  54.     )
  55. )
  56.  
  57. (set #CI_drive ("DF%ld:" #CI_unit))
  58.  
  59. (makedir @default-dest
  60.     (help @makedir-help)
  61.     (infos)
  62. )
  63.  
  64. ;----------------------------
  65.  
  66. (if (= 0 #gamever)
  67. (
  68.  
  69. (message "\n\n\nThis loader needs the JST program (NOT INCLUDED)\n to be copied in your path\n\n(if you don't have it already)\n\nJST is available from aminet (game/patch) or on my site")
  70.  
  71. (copyfiles
  72.     (help @copyfiles-help)
  73.     (source "MagicPocketsHD")
  74.     (dest @default-dest)
  75. )
  76. (copyfiles
  77.     (help @copyfiles-help)
  78.     (source "MagicPocketsHD.icon")
  79.     (dest @default-dest)
  80.     (newname "MagicPocketsHD.info")
  81. )
  82. )
  83. (
  84.  
  85. (copyfiles
  86.     (help @copyfiles-help)
  87.     (source "MagicPockets.slave")
  88.     (dest @default-dest)
  89. )
  90. (copyfiles
  91.     (help @copyfiles-help)
  92.     (source "MagicPockets.icon")
  93.     (dest @default-dest)
  94.     (newname "MagicPockets.info")
  95. )
  96.  
  97.  
  98. )
  99. )
  100.  
  101. (copyfiles
  102.     (help @copyfiles-help)
  103.     (source "mphd.readme")
  104.     (dest @default-dest)
  105.     (infos)
  106. )
  107.  
  108. (message ("\nInsert %s disk into drive %s !" @app-name #CI_drive))
  109.     (if
  110.         (= 0 (run ("disk2file %ld \"%s/MP.d1\" >con:///1000//CLOSE/WAIT" #CI_unit @default-dest )))
  111.         ("")
  112.         (abort "\"disk2file\" must be in your PATH !")
  113.     )
  114.  
  115.  
  116. (exit)
  117.  
  118.